/**
 *
 */
package net.miguelgarcia;

/**
 * @author mikel
 *
 */
public class Exercici3 {

	/**
	 * @param args
	 */

	public static void main(String[] args) {
		int DECIMAL = 5;
		String binari = "";
		if (DECIMAL == 1) {
			binari = binari + "1";
			System.out.println(binari);
		}
		while (DECIMAL / 2 >= 1) {
			binari = DECIMAL % 2 + binari;
			if (DECIMAL / 2 == 1) {
				binari = "1" + binari;
			}
			DECIMAL = DECIMAL / 2;
		}
		System.out.println(binari);

	}

}
